﻿namespace WP7Contrib.Diagnostics.Tests
{
    using System;
    using System.Windows;
    using Microsoft.Phone.Controls;

    public partial class MainPage : PhoneApplicationPage
    {
        public MainPage()
        {
            InitializeComponent();
            WP7Contrib.Diagnostics.RuntimeDebug.Initialize(true,true);
            this.Loaded += new RoutedEventHandler(MainPage_Loaded);
            
        }

        void MainPage_Loaded(object sender, RoutedEventArgs e)
        {
            WP7Contrib.Diagnostics.RuntimeDebug.Write("loaded");
        }

        private void button1_Click(object sender, RoutedEventArgs e)
        {
            WP7Contrib.Diagnostics.RuntimeDebug.Write("1");
        }

        private void button2_Click(object sender, RoutedEventArgs e)
        {
            WP7Contrib.Diagnostics.RuntimeDebug.Write("2");
        }

        private void button4_Click(object sender, RoutedEventArgs e)
        {
            throw new Exception("test exception");
        }
    }
}